#ifndef __LIGHTWEIGHT_OBJECT_ORENTED_KERNEL_HPP
#define __LIGHTWEIGHT_OBJECT_ORENTED_KERNEL_HPP

#define LOOK_TICKS_PER_SEC      1000
#define LOOK_STACK_SIZE         40
#define LOOK_IDLE_STACK_SIZE    0
#define LOOK_DEFAULT_TIMESLICE  (1000 / 50)

#define LOOK_SCHEDULING_HEADERFILE  <look/co.hpp>

#include <look/core.hpp>
#include LOOK_SCHEDULING_HEADERFILE

#ifndef LOOK_SCHEDULING
#error "the scheduler is not defined"
#else

#ifndef __STRINGIZE
#define __STRINGIZE(a)      __STRINGIZE_I(a)
#define __STRINGIZE_I(a)    #a
#endif

__asm__ __volatile__(
	".global .LOOK.SCHEDULING." __STRINGIZE(LOOK_SCHEDULING)	"\n\t"
	".weak .LOOK.SCHEDULING." __STRINGIZE(LOOK_SCHEDULING)	"\n\t"
	".set .LOOK.SCHEDULING." __STRINGIZE(LOOK_SCHEDULING) ",0"
);

namespace look {
using namespace LOOK_SCHEDULING;
extern sched_t scheduler;
}

#include <look/core.hpp>
#include LOOK_SCHEDULING_HEADERFILE
#include <look/instance.hpp>

using namespace look;

#endif  // LOOK_SCHEDULING
#endif  // __LIGHTWEIGHT_OBJECT_ORENTED_KERNEL_HPP
